Add Book to My BookshelfPurchase This Book Online

Chapter 1 - Router Basics

Cisco TCP/IP Routing Professional Reference
Chris Lewis
  Copyright © 1999 The McGraw-Hill Companies, Inc.

Router Concepts
This section introduces router technology and its responsibility in an internetwork, an accepted networking industry term for a set of many interconnected networks. Each individual network will have its own network number that must be unique for that particular internetwork. If some of the terms used here are unfamiliar, don't worry; all the ideas presented in this overview are discussed in more detail and explained fully in later chapters.
Routers direct traffic through an internetwork, based on information learned from network protocols. Let's discuss some of the goals of these computer network protocols.
With an internetwork that has hundreds or even thousands of computers linked together, there has to be some agreed-upon way for those devices to address one another and communicate. As a network grows larger, it is not feasible for each computer to keep track of the individual address of every other computer on the internetwork. There must be some scheme for reducing the amount of information each computer has to hold locally in order to communicate with every other computer.
The scheme used involves splitting an internetwork into many discrete but connected networks, which may themselves be split into subnetworks (Fig. 1-1). The job of keeping track of these discrete networks is then given to specialized computers called routers. Using this method, the network computers need only keep track of the networks on the internetwork, rather than keeping track of every network computer.
Figure 1-1: Interconnection of networks and subnetworks on an internetwork
The best analogy I can think of for describing how computers on an internetwork address each other is the postal service. When you address a letter, you provide an apartment number, street name and number, town, and state. In computer terms, messages are delivered by application port number, host number, subnet number, and network number (Fig. 1-2). These terms will be discussed fully in subsequent sections.
Figure 1-2: Comparing the Postal Service to an internetwork addressing scheme
The key concept is that when the postal service receives a letter for delivery to another town, the first thing postal workers do is to send it to the distribution office in the destination town. From there the letter goes to the people that deliver for that particular street, and finally, the letter is delivered to its destination.
Computer networks follow a similar process. The message sent on the internetwork initially gets sent to a router that is connected to the destination network number. This router, in effect acting as a distribution center for this network, will send the message out on the destination subnet number, and finally the message is delivered to the destination port number in the destination machine.
Figure 1-3 shows a simple internetwork with routers connecting different network numbers. In this figure, networks 1, 2, 3, and 4 have hosts on them and networks 5, 6, and 7 do not. Networks 5, 6, and 7 are there purely to connect the routers over a local or wide area network. In this internetwork, hosts X and Z must be configured for the same network number (in this case, 2). In addition, the router interfaces that are connected to the same network (for example, interface 2 on router C and interface 1 on router A), must be configured for the same network number (in this case, 5).
Figure 1-3: Simple internetwork connectivity
Using the postal service analogy again, routers that are connected to two networks can be thought of as houses that have entrances on two streets. In Fig. 1-4, we see a house that has two entrances, one on Subnet-1 Street and the other on Subnet-2 Street. Both the address on Subnet-1 Street and the address on Subnet-2 Street are good for purposes of delivering a letter to the house. This is analogous to a router being connected to two network numbers. In Fig. 1-3, the address for interface 1, interface 2, or interface 3 is good for delivering a message to router A.
Figure 1-4: Illustration of multiple addresses reaching the same location
Routers by their very nature seek to route packets from one network number to another. This statement has two immediate practical implications for us. First, you cannot configure the same network number on more than one interface on a router. (Much later we will cover the case in which subnet masks allow the same network number, but different subnet numbers, to be configured on different interfaces on the same router.) Second, because a broadcast has a destination network number, a router does not forward broadcasts by default. (Again, we will discuss later how a router can be configured to forward broadcast packets).
Routers Compared to Bridges
Routers typically are used to connect geographically dispersed networks together, and to make feasible connecting a large number of computers together. Before routers became popular, bridges often were used to achieve the same goals. Bridges were good for small networks, but had problems working in larger environments. Bridges keep track of all the individual computers on a network. The problem with using bridges to connect large numbers of computers together is that bridges do not understand network numbers, so any broadcast generated anywhere on the network gets sent everywhere. The difference between how routers and bridges handle broadcasts is illustrated in Fig. 1-5.
Figure 1-5: Illustration of how routers and bridges handle broadcasts differently
Many PC networking systems make extensive use of broadcasts, which leads to bridged networks having significant amounts of their usable bandwidth consumed by broadcasts.
At this point, it is worth contrasting the routing decisions made by routers and typical workstations or hosts on an internetwork.
A typical workstation (a PC running a popular TCP/IP stack, for example) will require some manual configuration before it can operate on a TCP/IP network. At a minimum, you will have to configure an IP address, a subnet mask, and a default gateway.
The routing decisions of a workstation configured in this manner are simple. If the workstation has to send a packet to another machine that is on the same network number, the packet is sent directly to the destination machine. If the destination is on a different network number, the packet is forwarded to the default gateway for routing through the internetwork and on to the final destination.
Routers make more complex decisions. They must know how to get to all other network numbers on the internetwork and the best way to route the packets, and they need to keep track of an internetwork topology that is constantly changing due to equipment or other failures. To execute these responsibilities, a router maintains a routing table, which lists all the known network numbers and how to get to them. Routers also use routing protocols that keep the routing table accurate for a changing internetwork.
Routers Compared to Other Computers
Now let's look at how a Cisco router is similar to and different from other computers on an internetwork. A router is similar to other computers in that it has memory, an operating system, a configuration, and a user interface. (In Cisco routers, the operating system is called the Internetwork Operating System, or IOS, and is proprietary to Cisco.) A router also has a boot process similar to other computers in that bootstrap code is loaded from ROM, which enables the machine to load its operating system and configuration into memory.
What makes a router different from other computers is the user interface and the configuration of memory.
Router Memory Types.     Typically a DOS or Unix system has one physical bank of memory chips that will be allocated by software to different functions. Routers have separate banks of memory, each dedicated to a different function. The function of these memory banks also differs between routers. An overview of the function of router memory types is presented in Table 1.1.
ROM.     Read-only memory (ROM) contains a copy of the IOS that the router is using. The 7000-series routers have ROM chips on the route processor board. The 4000 has ROM chips on the motherboard. In the 7000 and the 4000, the ROM chips can be upgraded to contain new versions of IOS. In the 2500 router and 1000-series LAN extender, the ROM chips cannot be upgraded and contain a very limited operating system, just enough to make the router operational. The IOS for a 2500-series router is contained in what is known as flash memory.
Table 1.1: Summary of Router Memory Details
Type of Memory
7000
4000
2500
ROM
Upgradeable IOS
Upgradeable IOS
Non-upgradeable basic OS
RAM Shared
Storage Buffers
Storage Buffers
Storage Buffers
RAM Main
IOS loaded from Flash, plus route tables and other data structures
as 7000
Routing tables and other IOS data structures only
Flash
Contains IOS
Contains IOS
Contains IOS (Router runs IOS from flash)
NVRAM
Config files
Config files
Config files
Note: Because the 2500 series runs its IOS from flash memory, a 2500 might not have enough memory in it to have the IOS upgraded while the router is running. In the 7000 and 4000 series the IOS is running in main RAM; therefore flash can be upgraded while the router is running.
If you are running a version of Cisco IOS earlier than version 11, you will see one unnerving feature of the 2500 series if you attach a terminal to the console port during boot-up. The ROM IOS checks the configuration file and will not recognize most of the commands. This results in many error messages being reported to the screen. This is normal operation. When the IOS in flash memory loads, normally no error messages are displayed.
RAM.     Random access memory (RAM) is split by the IOS into shared and main memory. Main memory is used to store router configuration and IOS data structures relevant to the protocol being routed. For IP, main memory is used for such things as holding routing tables and ARP tables; for IPX, main memory holds SAP and other tables. (These terms are explained later.)
Shared memory buffers packets waiting to be processed. This type of memory is only used by 4000- and 2500-series routers. The 7000 routers have a switch processor that controls the flow of packets through the router.
Flash Memory.    Flash memory holds the current version of IOS running on the router. Flash memory is erasable memory that can be overwritten with newer versions of the IOS—unlike ROM, which is located in physical chips that cannot have their contents overwritten.
NVRAM.     Nonvolatile RAM (NVRAM) does not lose its contents when the router is switched off. NVRAM holds the router configuration.
Booting a Router.     Routers boot up in a similar fashion to PCs; the procedure is as follows:
  1. Load bootstrap program from ROM.
  2. Load operating system (IOS, the Internetwork Operating System) from flash memory.
  3. Find and load configuration file in NVRAM or on a prespecified network server. If no configuration file exists, the router enters setup mode.

 


 
Books24x7.com, Inc © 2000 –  Feedback